package com.atguigu.day22.refltct05.r1;

public class Person {
    String name;
    int age;
    double height;
    double salary;

    public Person() {
        System.out.println("---Person 无参");
    }

    protected Person(String name, int age) {
        this.name = name;
        this.age = age;
    }

    private Person(String name, int age, double height) {
        this.name = name;
        this.age = age;
        this.height = height;
    }

     Person(String name, int age, double height, double salary) {
        this.name = name;
        this.age = age;
        this.height = height;
        this.salary = salary;
    }

    @Override
    public String toString() {
        return "Person{" +
                "name='" + name + '\'' +
                ", age=" + age +
                ", height=" + height +
                ", salary=" + salary +
                '}';
    }
}
